﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Model
{
    public class Product
    {
        public long ID { get; set; }
        public string Name { get; set; }
        public decimal Price { get; set; }
        public string Summary { get; set; }
        public string Detail { get; set; }
        public string IndexImage { get; set; }
    }

    public class ProductListView : Product
    {
        bool imageChanged = false;
        byte[] indexImageArray;

        public string CategoryList { get; set; }
        public string KeyList { get; set; }
        public bool Selected { get; set; }

        public byte[] IndexImageArray
        {
            get { return indexImageArray; }
            set { indexImageArray = value; imageChanged = true; }
        }

        public bool ImageChanged
        {
            get { return imageChanged; }
            set { imageChanged = value; }
        }
    }
}
